<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
<title>HUI 滑动事件</title>
<link rel="stylesheet" type="text/css" href="../css/hui.css" />
</head>
<body>
<header class="hui-header">
    <div id="hui-back"></div>
    <h1>HUI 滑动事件</h1>
</header>
<div class="hui-wrap">
    <div class="hui-center-title" style="margin-top:15px;"><h1>演示样例</h1></div>
    <div style="margin:30px 20px; text-align:center; line-height:300px; height:300px; color:#FFFFFF; background:#26A2FF;" id="demo1">
    	在蓝色div上面滑动手指试试 ^_^
    </div>
</div>
<script type="text/javascript" src="../js/hui.js" charset="UTF-8"></script>
<script type="text/javascript">
hui('#demo1').swipe(function(e){
    hui('#demo1').html('X: ' + e.deltaX + ' Y : '+ e.deltaY);
});
hui('#demo1').swipeLeft(function(e){hui.toast(e.type);});
hui('#demo1').swipeRight(function(e){hui.toast(e.type);});
hui('#demo1').swipeUp(function(e){hui.toast(e.type);});
hui('#demo1').swipeDown(function(e){hui.toast(e.type);});
</script>
</body>
</html>